//
//  OrderHalfButton.h
//  B2C
//
//  Created by 李小龙 on 2017/8/15.
//  Copyright © 2017年 lixiaolong. All rights reserved.
//

#import <UIKit/UIKit.h>

typedef NS_ENUM(NSUInteger, OrderButtonType) {
    OrderButtonTypeService, // 客服
    OrderButtonTypePay,     // 付款
    OrderButtonTypeCancel,  // 取消订单
    OrderButtonTypeAlert,   // 提醒发货
    OrderButtonTypeCheck,   // 查看物流
    OrderButtonTypeSure,    // 确认收货
    OrderButtonTypeDelete,  // 删除订单
    OrderButtonTypeEvaluate,// 评价
    OrderButtonTypeRefundDetail,  // 退款详情
    OrderButtonTypeRefundCancel,  // 取消退款
    OrderButtonTypeRefundAgain,   // 重新申请
    OrderButtonTypeRefundDone,    // 申请通过
    OrderButtonTypeStoreClose,          // 关闭订单
    OrderButtonTypeStoreChangePrice,    // 修改价格
    OrderButtonTypeStoreSendOut,        // 去发货
    OrderButtonTypeStoreRefund,         // 退货申请
    OrderButtonTypeStoreCheck,          // 查看物流
    OrderButtonTypeStoreCheckEvaluate,  // 查看评价
    OrderButtonTypeStoreDelete,         // 删除订单
    OrderButtonTypeStoreRefundSuccess,  // 店铺退款 成功
    OrderButtonTypeStoreRefundFail,     // 店铺退款 失败
    OrderButtonTypeStoreRefundRejected, // 店铺退款 已驳回
    OrderButtonTypeStoreRefundReject,   // 店铺退款 拒绝退款
    OrderButtonTypeStoreRefundAgree,    // 店铺退款 同意申请
};

@interface OrderHalfButton : UIButton

@property (nonatomic, assign) OrderButtonType type;

/**
 初始化方法

 @param type 按钮类型
 @param frame 按钮坐标、大小
 @param buttonTitle 按钮标题
 @param color 文字颜色
 @param borderColor 边框颜色
 @return 按钮
 */
+ (instancetype)orderButtonWithType:(OrderButtonType)type
                              frame:(CGRect)frame
                        buttonTitle:(NSString *)buttonTitle
                              color:(UIColor *)color
                        borderColor:(UIColor *)borderColor;

/**
 设置按钮的样式

 @param type 类型
 @param buttonTitle 标题
 @param color 文字颜色
 @param borderColor 边框颜色
 */
- (void)setOrderButtonStyleWithType:(OrderButtonType)type
                        buttonTitle:(NSString *)buttonTitle
                              color:(UIColor *)color
                        borderColor:(UIColor *)borderColor;
@end
